package cn.tedu.v1.vo;

import lombok.Data;
import lombok.experimental.Accessors;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

@Data
@Accessors(chain = true)
public class AppointmentVo {
    @NotBlank( message="病人姓名不能为空")
    @Pattern(regexp ="[\u4e00-\u9fa5]{2,4}",message ="姓名应为2-4个汉字")
    private String name;
    @NotBlank(message="联系电话不能为空")
    @Pattern(regexp = "^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\\d{8}$",message = "请输入正确的手机号码")
    private String phone;
    @NotNull(message = "用户年龄不能为空")
    private Integer age;
    @NotNull(message = "用户id不能为空")
    private Integer userId;
    @NotNull(message="预约科室不能为空")
    private Integer officeId;
    @NotNull(message="预约医生不能为空")
    private Integer doctorId;
    @NotBlank(message="预约时间不能为空")
    private String appointtime;
    @NotBlank(message="症状描述能为空")
    private String description;
    @NotBlank(message="性别不能为空")
    private String sex;
    private Integer id;
}
